#ifndef _MISSING_VIEW_CHANGE_HPP
#define _MISSING_VIEW_CHANGE_HPP 1

#include "MacMessage.hpp"

namespace BFT
{
	namespace order
	{
		namespace messages
		{
			class MissingViewChange : public BFT::messages::MacMessage
			{
				public:
				
				MissingViewChange(uint32_t _view, uint32_t _replicaId, uint32_t _sendingReplica);
				
				MissingViewChange(boost::shared_ptr<char> _bytes, int _bytes_size);
				
				uint32_t getView(); //inlined
				 
				uint32_t getMissingReplicaId(); //inlined
				
				uint32_t getSendingReplica(); //inlined
				
				bool equals(boost::shared_ptr<MissingViewChange> _other_mvc);
				
				protected:
				
				uint32_t viewNo;
				uint32_t missingReplicaId;
			};
			
			inline uint32_t MissingViewChange::getView() {return viewNo;}
			inline uint32_t MissingViewChange::getMissingReplicaId() {return missingReplicaId;}
			inline uint32_t MissingViewChange::getSendingReplica() {return getSender();}
		}
	}
}

#endif
